import type { RouteRecordRaw } from 'vue-router'
import { AppstoreOutlined } from '@ant-design/icons-vue'
import Layout from '@/layout/index.vue'

export const routes: RouteRecordRaw[] = [
  {
    path: '/',
    redirect: '/attendanceManagement/index',
    component: Layout,
    meta: {
      title: '考勤管理',
      icon: AppstoreOutlined,
    },
    children: [
      {
        path: '/attendanceManagement/index',
        name: 'attendanceManagementIndex',
        component: () => import('@/module/attendanceManagement/pages/attendance/index.vue'),
        meta: {
          title: '考勤统计',
        },
      },
      {
        path: '/attendanceManagement/setting',
        name: 'attendanceManagementSetting',
        component: () => import('@/module/attendanceManagement/pages/attendance/setting.vue'),
        meta: {
          title: '补班日设置',
        },
      },
    ],
  },
  {
    path: '/information',
    component: Layout,
    meta: {
      title: '信息管理',
      icon: AppstoreOutlined,
    },
    children: [
      {
        path: '/information/employee',
        name: 'employeeIndex',
        component: () => import('@/module/informationManagement/pages/employee/index.vue'),
        meta: {
          title: '员工资料',
        },
      },
    ],
  },
]
